﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using QuanLyThuVien.Business;
using System.Windows.Forms;

namespace QuanLyThuVien.DataAccess
{
    class UserDAL
    {
        clsDatabase db = new clsDatabase();
        
        public bool KiemTraUser(User user)
        {
            string strSQL = "select count(*) from tbUser  where( User='" + user.USER + "' and Pass='" + user.Pass+ "')";
            return db.KiemTraUserName(strSQL);
        }

        public void DangKiUser(User user)
        {
            db.ThuThiSQL("insert into tbUser values ('"+user.USER+"','"+user.Pass+"')");
        }
    }
}
